/* eslint-disable */
import {
    axios
} from '@/utils/request';
const api = {
    unitList: "/share-parking/web/unit/list", //查询所有小区列表
    myUnitList: "/share-parking/web/personCenter/myUnitList", //查询我的小区列表
    commitMyUnit:"/share-parking/web/personCenter/commitMyUnit", //申请关联小区
    mySpaceList: "/share-parking/web/personCenter/mySpaceList", //我的车位
    getUnitspaceList: "/share-parking/web/personCenter/myUnitSpaceList", //我的小区车位接口
    applyParkingSpace:  "/share-parking/web/personCenter/applyParkingSpace", //车位主提交车位申请

}
export function unitList(parameter) {
    return axios({
        url: api.unitList,
        data: parameter,//params
        method: 'POST'
    })
}

export function myUnitList(parameter) {
    return axios({
        url: api.myUnitList,
        params: parameter,//params
        method: 'get'
    })
}

export function commitMyUnit(parameter) {
    return axios({
        url: api.commitMyUnit,
        params: parameter,//params
        method: 'get'
    })
}

export function mySpaceList(parameter) {
    return axios({
        url: api.mySpaceList,
        params: parameter,//params
        method: 'get'
    })
}

export function getUnitspaceList(parameter) {
    return axios({
        url: api.getUnitspaceList,
        params: parameter,//params
        method: 'get'
    })
}

export function applyParkingSpace(parameter) {
    return axios({
        url: api.applyParkingSpace,
        data: parameter,//params
        method: 'POST'
    })
}
